Ext.define('SA.view.survey.QuestionEditor', {
	extend: 'Ext.window.Window',
	alias: 'widget.questioneditor',
	
	title: 'Edit Question',
	layout: 'fit',
	autoShow: true,

	initComponent: function() {
		this.items = [{
			xtype: 'form',
			items: [{
				xtype: 'combobox',
				fieldLabel: 'Question Type',
				name: 'questionTypeId',
				queryMode: 'local',
				store: 'QuestionTypes',
				valueField: 'id',
				displayField: 'name'
			}, {
				xtype: 'textarea',
				fieldLabel: 'Question',
				name: 'questionText',
				allowBlank: false,
				resizable: true,
				resizeHandles: 'se',
				width: 300,
				maxWidth: 500,
				minWidth: 400,
				maxHeight: 150,
				minHeight: 60
				
			}, {
				xtype: 'textfield',
				fieldLabel: 'Weight',
				name: 'weight',
				width: 150,
				allowBlank: false
			}, {
				xtype: 'textarea',
				fieldLabel: 'Answers',
				name: 'answerText',
				allowBlank: false,
				resizable: true,
				resizeHandles: 'se',
				width: 300,
				maxWidth: 500,
				minWidth: 400,
				maxHeight: 150,
				minHeight: 60
				
			}]
		}]
		this.callParent(arguments);
		
	}
	
});